/**
 * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
 *
 * This library is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 */

package rigo.ricard.pris.rs.ac.uns.dmi.model.impl;

import com.liferay.portal.kernel.util.StringBundler;
import com.liferay.portal.kernel.util.StringPool;
import com.liferay.portal.model.CacheModel;

import rigo.ricard.pris.rs.ac.uns.dmi.model.CarPicture;

import java.io.Serializable;

/**
 * The cache model class for representing CarPicture in entity cache.
 *
 * @author Rigo Richard
 * @see CarPicture
 * @generated
 */
public class CarPictureCacheModel implements CacheModel<CarPicture>,
	Serializable {
	@Override
	public String toString() {
		StringBundler sb = new StringBundler(7);

		sb.append("{carPicureId=");
		sb.append(carPicureId);
		sb.append(", adId=");
		sb.append(adId);
		sb.append(", fileName=");
		sb.append(fileName);
		sb.append("}");

		return sb.toString();
	}

	public CarPicture toEntityModel() {
		CarPictureImpl carPictureImpl = new CarPictureImpl();

		carPictureImpl.setCarPicureId(carPicureId);
		carPictureImpl.setAdId(adId);

		if (fileName == null) {
			carPictureImpl.setFileName(StringPool.BLANK);
		}
		else {
			carPictureImpl.setFileName(fileName);
		}

		carPictureImpl.resetOriginalValues();

		return carPictureImpl;
	}

	public long carPicureId;
	public long adId;
	public String fileName;
}